fix(integ-test): Fix Integ test issue after making Apache5 as default#6974
Merged
Merged
Conversation
… policy for Apache 5 compatibility. Apache 5.6 sets TCP_KEEPIDLE/INTERVAL/COUNT by default which requires jdk.net.NetworkPermission.
… exception assertion
…ransitivity. The test scope override prevented downstream modules like s3-transfer-manager from discovering the HTTP client via SPI
…ption in ResponseInputStreamTimeoutIntegrationTest
…tegrationTest and asserting just on error message
Fred1155
approved these changes
May 18, 2026
|
This pull request has been closed and the conversation has been locked. Comments on closed PRs are hard for our team to see. If you need more assistance, please open a new issue that references this one. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Update tests for Apache HttpClient 5 compatibility: TCP keep-alive permissions, exception assertions, and dependency cleanup
Motivation and Context
Click here to expand the long callstack
ResponseInputStreamTimeoutIntegrationTestpreviously asserted onorg.apache.http.conn.ConnectionPoolTimeoutException(Apache 4 specific). After the Apache 5 migration, the actual exception type changes, causing dependency analysis to fail since it found classes of Apache5 that were undeclared dependencies (not defined in s3/pom.xml)Click here to expand the long callstack
services/s3/pom.xmldeclaredapache5-clientwith<scope>test</scope>, duplicating what's already inherited fromservices/pom.xmlat<scope>runtime</scope>. Runtime-scope dependencies are available on the testCompile classpath, so the explicit test-scope declaration was causing s3-transfer manager test failures as belowClick here to expand the long callstack
Modifications
services/dynamodb/.../security-manager-integ-test.policy: Addedjdk.net.NetworkPermissionentries forsetOption.TCP_KEEPIDLE,setOption.TCP_KEEPINTERVAL, andsetOption.TCP_KEEPCOUNTto allow the SecurityManager test to pass with Apache HttpClient 5.6's default TCP keep-alive behavior.services/s3/.../ResponseInputStreamTimeoutIntegrationTest.java: Removed the import and assertion onConnectionPoolTimeoutException(Apache 4-specific class). Replaced the exception type check with a message-only assertion (hasMessageContaining("Timeout deadline")) to make the test independent of the underlying HTTP client classes.services/s3/pom.xml: Removed the redundantapache5-clienttest-scope dependency declaration. The dependency is already inherited fromservices/pom.xmlat runtime scope, which provides classpath visibility for both test compilation and execution.License